
function loadMsgCount() {
	$.ajax({url:"/xinlu/user/yhxxAction.html", type:"post", async:true, cache:false, data:{pageId:"yhxx", doAction:"loadMsgCount", }, success:function (data) {
		var vs = data.split(";");
		document.getElementById("msgcount").innerHTML = "<font color=red>" + vs[1] + "</font>";
		if (vs[0] == "true") {
			var _left = document.body.clientWidth-200;
			var _top = document.body.clientHeight-100;
			window.showModelessDialog("/xinlu/jsp/user/newMsg.jsp", vs[1], "status=no;help=no;dialogWidth=200px;dialogHeight=100px;dialogLeft=" + _left + "px;dialogTop=" + _top + "px;");
		}
	}, error:function (data) {
		document.getElementById("msgcount").innerHTML = 0;
	}});
	setTimeout("loadMsgCount()", 300000); // 三分钟查一次
}
loadMsgCount();

